action-bar: Add start and end style classes to GtkActionBar boxes
authorAlexander Mikhaylenko <alexm@gnome.org>
Sun, 9 May 2021 11:54:59 +0000 (16:54 +0500)
committerAlexander Mikhaylenko <alexm@gnome.org>
Sun, 9 May 2021 11:54:59 +0000 (16:54 +0500)
Make it possible to add spacing to them from the theme without affecting
the center child should it happen to be a box.

gtk/gtkactionbar.c

index 8058fecde0d2cda174fe9c3bf9796b6103a62d52..e82ed3d7c0d02b1fed651f31329bd665c8eeeba7 100644 (file)
@@ -181,6 +181,9 @@ gtk_action_bar_init (GtkActionBar *self)
   self->start_box = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
   self->end_box = gtk_box_new (GTK_ORIENTATION_HORIZONTAL, 0);
 
+  gtk_widget_add_css_class (self->start_box, "start");
+  gtk_widget_add_css_class (self->end_box, "end");
+
   self->center_box = gtk_center_box_new ();
   gtk_center_box_set_start_widget (GTK_CENTER_BOX (self->center_box), self->start_box);
   gtk_center_box_set_end_widget (GTK_CENTER_BOX (self->center_box), self->end_box);